<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        #container{
            width: 100%;
            height: 100vh;
        }
    </style>
</head>
<body>
    <div id='container'></div>
    <script type="text/javascript"  src="https://webapi.amap.com/maps?v=2.0&key=ea6747d0f0d2eb47a7306376edb1dee0"></script>
    <script>
        const map = new AMap.Map('container', {
            zoom: 11,
            center: [116.397428, 39.90923]
        });
        const points=[
            {
                name:'zsss',
                position:[116.397428, 39.90923]
            },
            {
                name:'lsss',
                position:[116.397428, 39.90923]
            }
        ];
        for( const point of points){
            const marker = new AMap.Text({
                position: point.position,
                text:point.name,
                anchor:'bottom-center',
                draggable:true,
                cursor:'pointer',
                style:{
                    'padding':'5px 10px',
                    'background-color':'#fff',
                    'border-width':0,
                    'border-radius':'4px',
                    'box-shadow':'0 1px 3px 0 rgba(0,0,0,0.1)',
                    'text-align':'center',
                    'font-size':'12px',
                    'color':'#333'

                }
            });
            marker.setMap(map);
        }

    </script>
</body>
</html>
